#include "header.hpp"
using namespace std;

void printString(const string& str){
    cout << "Parameter is left value reference" << endl;
    cout << str << endl;
}

void printString(string&& str){
    cout << "Parameter is right value reference" << endl;
    cout << str << endl;
}

void test1(){
    string a = "hello";
    string b = "world";
    string c = a + b;

    printString(c);

    //Even if the parameter is const lval reference
    //Invoke of function still choose which one the parameter is rval reference
    printString(a + b);
}
